// package-activity/pages/spokes-stats/index.js
import { showLoading, hideLoading } from '../../../common/env';
import { statsIncomeActivity } from '../../../api/spn';
let spokesmanId, activityId;

Page({
    data: {
    },
    onLoad(options) {
        spokesmanId = options.spokesmanId;
        activityId = options.activityId;
        this._handleGetDetail();
    },
    async _handleGetDetail() {
        showLoading('加载中...');
        const statsInfo = await statsIncomeActivity({ spokesmanId, activityId });
        this.setData({ statsInfo });
        console.log('SpokesStats => 活动数据统计=>收入', statsInfo);
        hideLoading();
    },
})
